﻿@model DashboardModel

@using Nop.Services.Security

@{
    Html.AppendCssFileParts("~/Administration/Content/ionicons/css/ionicons-2.0.1.min.css");

    //page title
    ViewBag.Title = T("Admin.Dashboard").Text;

    var permissionService = EngineContext.Current.Resolve<IPermissionService>();
    var canManageReports = permissionService.Authorize(StandardPermissionProvider.ManageReports);
}

@Html.AntiForgeryToken()
<div class="content-header">
    <h1>
        @T("Admin.Dashboard")
    </h1>
</div>

<div class="content">
    <div class="row">
        <div class="col-md-12">
            <div class="row">
                <div class="col-md-12">
                    @Html.Action("CommonStatistics", "Home")
                </div>
            </div>
            @if (canManageReports)
            {
                <div class="row">
                    <div class="col-md-6">
                        @Html.Action("Statistics", "Maintenance")
                    </div>
                    <div class="col-md-6">
                        @Html.Action("Statistics", "Inspection")
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-6">
                        @Html.Action("ReportByUser", "Maintenance")
                    </div>
                    <div class="col-md-6">
                        @Html.Action("ReportByEquipment", "Maintenance")
                    </div>
                </div>
                <div class="row">
                    <div class="col-md-6">
                        @Html.Action("ReportByEquipment", "EquipmentStockOut")
                    </div>
                    <div class="col-md-6">
                    </div>
                </div>
            }
        </div>
    </div>
</div>
